package Demo;

public class ClassTest {
    public static void main(String[] args) {
       MyArray myArray = new MyArray();
       myArray.add(1);
       myArray.add(2);
       myArray.add(3);
       myArray.add(4);
       myArray.display();

        myArray.remove(1);
        myArray.display();
      /* try{
           myArray.add(1,99);
       }catch (IndexOutOfException e){
           e.printStackTrace();
       }
       myArray.display();
       System.out.println("==============");

        try{
            System.out.println(myArray.get(1));;
        }catch (IndexOutOfException e){
            e.printStackTrace();
        }*/
    }
}
